@extends('admin.layouts.application')

@section('title')
    <title>修改订单</title>
@stop

@section('content')
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="col-sm-12">
            <div class="ibox float-e-margins">
                <div class="ibox-title">
                    <h5>修改订单</h5>
                </div>
                <div class="ibox-content">
                    @include('edu.layouts.msg')
                    <form class="form-horizontal m-t" action="{{route('admin.betting.edit')}}"
                          method="post">
                        {{csrf_field()}}
                        <input type="hidden" name="id" value="{{$betting->id}}">
                        <div class="form-group">
                            <label class="col-sm-3 control-label">种类</label>
                            <div class="col-sm-2">
                                <select name="type_id" id="" class="form-control m-b">
                                    @foreach($types as $type)
                                        <option value="{{$type->id}}">{{$type->name.',赔率'.$type->price}}</option>
                                    @endforeach
                                </select>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-3 control-label">客户名称：</label>
                            <div class="col-sm-2">
                                <input value="{{$betting->user_name}}" name="name" class="form-control"
                                       type="text">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-3 control-label">临时赔率(100元计)：</label>
                            <div class="col-sm-2">
                                <input value="{{$betting->temporary}}" name="temporary" class="form-control"
                                       type="number">
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="col-sm-3 control-label">金额：</label>
                            <div class="col-sm-2">
                                <input value="{{$betting->price}}" min="100" max="2000000" required name="price" class="form-control"
                                       type="number">
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="col-sm-3 control-label">备注：</label>
                            <div class="col-sm-2">
                                <input value="{{$betting->des}}" name="des" class="form-control"
                                       type="text">
                            </div>
                        </div>
                        <div class="form-group">
                            <div class="col-sm-8 col-sm-offset-3">
                                <button class="btn btn-primary" type="submit">
                                    提交
                                </button>
                            </div>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>
@endsection
